home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Collection of Tools & Utilities
/
Collection of Tools and Utilities.iso
/
tex
/
sf2pk200.zip
/
SFPTOPK.TXT
< prev
Wrap
Text File
|
1992-04-15
|
34KB
|
824 lines
[This ASCII version of the documentation is provided for on-line reference]
[only, it is not intended as a substitute for the "real" documentation ]
SFPtoPK
SFPtoPK converts HP LaserJet softfont files into TeX PK & TFM files
Version 2.0
Copyright (c) 1991-92 by Small Planet Software
All Rights Reserved
THIS PROGRAM IS ABSOLUTELY FREE. THIS PROGRAM IS PROVIDED
``AS IS'' WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND
PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL
NECESSARY SERVICING, REPAIR OR CORRECTION.
IN NO EVENT WILL ANY COPYRIGHT HOLDER BE LIABLE TO YOU
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL
OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR
INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR
LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF
THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
Every reasonable effort has been made to assure the quality and
completeness of this program, if you have any questions, comments, or
suggestions or if you believe that you have found a bug please contact
the author at the address given at the end of this document.
All trademarks used within this document are trademarks of their
respective owners.
Changes (what's new and exciting)
---------------------------------
Version 2.0
o Added support for HP AutoFont Support files.
Version 1.35
o Added mathmatical calculation of space parameters (see /spacenorm...)
o Fixed bug that prevented /spaceadj from being negative
o Added space and space adjustment to configuration file
Version 1.34
o Made SFPtoPK report attempts to delete explicitly (re)mapped characters
Version 1.33
o Faster I/O on some softfonts, minor documentation changes
Version 1.32
o Included PKscale program for creating scaled PK files
o Improved speed of ``scanning font'' code for most fonts
o Fixed bug that caused SFPtoPK to miss some accent problems
Version 1.31
o Never officially released
Version 1.3
o First real release
o SFPtoPK didn't print a message if it couldn't find the kern file
o Added none.lig, none.krn, and none.map
Version 1.2
o Tentative real release, last beta
Versions prior to 1.2
o To save paper, changes made prior to version 1.2 are no longer reported
Usage
-----
SFPtoPK is run from the DOS command prompt. In order to keep the program
small and simple, a command-line interface has been chosen instead of
something more user-friendly.Many of the options have reasonable default
values and these can be set with a configuration file. The configuration
file is described below.The general format for running SFPtoPK looks like
this:
SFPTOPK softfont[.sfp] <pkfile[.pk]> <plfile[.pl]> </option1:value1>
</optionn:valuen>
Where:
softfont[.sfp] is the name of the HP LaserJet softfont file to convert to
TeX format.
pkfile[.pk] is the name of the TeX PK file to create. By default,
SFPtoPK will use the root name of the softfont file as the
root name for the PK file.
plfile[.pl] is the name of the TeX PL file to create. In order to use
the PK file created by SFPtoPK in TeX, you will also have
to use the standard TeXware utility PLtoTF to create a TFM
file from the PL file. By default, SFPtoPK will use the
root name of the PK file as the root name for the PL file.
/option is one of the following options: /map, /lig, /minchar,
/maxchar, /slantchar, /spacechar, /spaceadj, /spacenorm,
/spacebold, /spaceital, /spacehmi, /xchar, /xadj, /krn,
/krows, /kcols, /kpdots, /kmax, /kadj, /ktbl, or
/auto.These options allow you to adjust the TeX font that
SFPtoPK produces. Each of these options is described in
more detail below.
Options
-------
/map:filename
-------------
HP softfonts frequently contain many of the ligatures and accents TeX uses
but they are in different ASCII positions; the /map option allows you to
rearrange characters in the font. Each line in the map file should identify
two characters (ASCII positions really), the character in the first
position in the softfont will be moved to the second position in the PK
file.
A word about characters: whenever SFPtoPK expects a character specification
in a file (or a command line option), it can be done in four different
ways.These four ways correspond to TeX notational conventions for
indicating decimal, octal, and hexidecimal numbers and literal characters.
The first way is to simply indicate the ASCII position with a decimal
number (65, for example), the second way is to indicate the position with
an octal number prefixed with a ' character ('101), the third way is to use
an hexidecimal number prefixed with a " character ("41), and the fourth way
is to use a character constant prefixed with a ` character (`A).
Consider, for example, the following lines from a map file:
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% This is a substitution map for \SFPtoPK. This map is for HP softfonts
% with symbol set 10J (PS Text).
"A1 '074
170 '134
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
If this map file is used, the character at position A1 (hex) in the
softfont file will appear in position 74 (octal) in the PK file (similarly
for 170 (decimal) and 134 (octal), etc). As you can see, %-style comments
are allowed in the map file.
The default mapping for all characters not present in the map file is to
it's ``natural'' position, the same position it has in the softfont file,
in the PK file. SFPtoPK will only use this mapping if the position is
available in the PK file (i.e. if no other character has been mapped to
that position).
If the second ``character'' in the map-pair is the word REMOVE, the
softfont character will not be present in it's natural position in the PK
file even if the position is available.
Mapping has a higher precedence than removing. An attempt to remove a
character that has been explicitly mapped will produce a warning message
and the character will not be removed. For example, if the map file
indicates that the character at position "7F should come from position "BA
in the softfont and that the character at position "7F should be removed,
the character will come from "BA even if the remove command appears later
in the map file.It is obviously silly to attempt to do both, and the
warning message will give you a clue that you have done something wrong. (I
spent more than an hour looking for a bug in SFPtoPK before I discovered
that I'd made a typo in my map file :::).
The map file also allows several options for manipulating character
accents. When the character is mapped to it's new position, you may specify
that only the accent or only the character is to be moved. It is even
possible to specify that only baseline accents (like the cydil `` '')
should be moved.In this way it is possible to form dotless 's and 's for
TeX and to take accents that are not present as individual symbols off of
characters that have t